<script setup lang="ts">
// import TestStore from "./views/testStore.vue";
// import List from './components/List.vue'
// import axios from 'axios'

// // 引入别名
// import type { ChannelItem, ChannelRes } from './types/data'
// // 获取列表
// const channelList = ref<ChannelItem[]>([])
// const getList = async () => {
// 	const res = await axios.request<ChannelRes>({
// 		url: 'http://geek.itheima.net/v1_0/channels',
// 		method: 'GET',
// 	})
// 	channelList.value = res.data.data.channels
// 	console.log(channelList.value, 'channelList.value')
// }
// onMounted(() => getList())
// //切换tab方法
// const channelId = ref(0)
// const tabChange = (id: number) => {
// 	channelId.value = id
// }
</script>

<template>
	<router-view></router-view>
	<router-link to="/test1">链接到首页</router-link>
	<!-- <TestStore /> -->
	<!-- <van-tabs @change="tabChange">
		<van-tab v-for="item in channelList" :key="item.id" :title="item.name">
			<List :channel-id="channelId" />
		</van-tab>
	</van-tabs> -->
</template>

<style scoped></style>
